//
//  BiApplyForSaleViewController.m
//  TrunkIndustryManageSystem
//
//  Created by 李璐西 on 15-4-13.
//  Copyright (c) 2015年 李璐西. All rights reserved.
//
#import "BiBaseViewController.h"
#import "BiApplyForSaleViewController.h"

@interface BiApplyForSaleViewController ()<UIScrollViewDelegate,UIPickerViewDataSource, UIPickerViewDelegate>
@property (nonatomic,strong) NSArray * carType;
@end

@implementation BiApplyForSaleViewController
NSArray * carType;
- (void)viewDidLoad
{
    [super viewDidLoad];
    [self setNavBarWithHidden:NO];
    [self setNavBarTitle:@"申请行销"];
    [self setNavBackBtn];
// scrollview -----------------
    CGRect frame = [self.view bounds];
    UIScrollView *background = [[UIScrollView alloc] initWithFrame:CGRectMake(0, 64, frame.size.width, frame.size.height)];
    [self.view addSubview:background];
    background.backgroundColor = [UIColor colorWithRed:240.0/255.0 green:242.0/255.0 blue:247.0/255.0 alpha:100];
    //    滚动
    background.contentSize = CGSizeMake(320, frame.size.height + 100);
    background.delegate = self;
#pragma mark define--------------------
    //   background1*********************************************************
    //    lables and image
#define ConFontOfSize 14
#define LineHeight 44
#define CellHeight 35
#define CellWidth  80
#define LeftMargin 10
    
#pragma mark line1--------------------
    UILabel *label_l1_01 = [[UILabel alloc] initWithFrame:CGRectMake(LeftMargin, 10, CellWidth, CellHeight)];
    label_l1_01.text = @"申请人:";
    label_l1_01.font = [UIFont systemFontOfSize:ConFontOfSize];
//    label_l1_01.backgroundColor = [UIColor blueColor];
    [background addSubview:label_l1_01];
    
    UITextField *proposerTextField = [[UITextField alloc] initWithFrame:CGRectMake(75, 10, CellWidth, CellHeight)];
    proposerTextField.delegate = self;
    proposerTextField.contentVerticalAlignment = UIControlContentVerticalAlignmentCenter;//垂直居中
    proposerTextField.borderStyle = UITextBorderStyleRoundedRect;
    [background addSubview:proposerTextField];
    proposerTextField.placeholder = @"";
    proposerTextField.font = [UIFont systemFontOfSize:ConFontOfSize];
    
    UILabel *label_l1_02 = [[UILabel alloc] initWithFrame:CGRectMake(160, 10, CellWidth, CellHeight)];
    label_l1_02.text = @"参与人:";
    label_l1_02.font = [UIFont systemFontOfSize:ConFontOfSize];
    [background addSubview:label_l1_02];
    
    UITextField *participantTextField = [[UITextField alloc] initWithFrame:CGRectMake(225, 10, CellWidth, CellHeight)];
    participantTextField.delegate = self;
    participantTextField.contentVerticalAlignment = UIControlContentVerticalAlignmentCenter;//垂直居中
    participantTextField.borderStyle = UITextBorderStyleRoundedRect;
    [background addSubview:participantTextField];
    participantTextField.placeholder = @"";
    participantTextField.font = [UIFont systemFontOfSize:ConFontOfSize];
#pragma mark line2--------------------
    UILabel *label_l2_01 = [[UILabel alloc] initWithFrame:CGRectMake(LeftMargin, 10 + LineHeight, CellWidth, CellHeight)];
    label_l2_01.text = @"目的地:";
    label_l2_01.font = [UIFont systemFontOfSize:ConFontOfSize];
    [background addSubview:label_l2_01];
    
    UITextField *destinationTextField = [[UITextField alloc] initWithFrame:CGRectMake(75, 10 + LineHeight, CellWidth, CellHeight)];
    destinationTextField.delegate = self;
    destinationTextField.contentVerticalAlignment = UIControlContentVerticalAlignmentCenter;//垂直居中
    destinationTextField.borderStyle = UITextBorderStyleRoundedRect;
    [background addSubview:destinationTextField];
    destinationTextField.placeholder = @"";
    destinationTextField.font = [UIFont systemFontOfSize:ConFontOfSize];
    
    UILabel *label_l2_02 = [[UILabel alloc] initWithFrame:CGRectMake(160, 10 + LineHeight, CellWidth, CellHeight)];
    label_l2_02.text = @"车牌:";
    label_l2_02.font = [UIFont systemFontOfSize:ConFontOfSize];
    [background addSubview:label_l2_02];
    
    
    UITextField *license_plateTextField = [[UITextField alloc] initWithFrame:CGRectMake(225, 10 + LineHeight, CellWidth, CellHeight)];
    license_plateTextField.delegate = self;
    license_plateTextField.contentVerticalAlignment = UIControlContentVerticalAlignmentCenter;//垂直居中
    license_plateTextField.borderStyle = UITextBorderStyleRoundedRect;
    [background addSubview:license_plateTextField];
    license_plateTextField.placeholder = @"";
    license_plateTextField.font = [UIFont systemFontOfSize:ConFontOfSize];
    #pragma mark line3--------------------
    UILabel *label_l3_01 = [[UILabel alloc] initWithFrame:CGRectMake(LeftMargin, 10 + LineHeight * 2, CellWidth, CellHeight)];
    label_l3_01.text = @"用车类型:";
    label_l3_01.font = [UIFont systemFontOfSize:ConFontOfSize];
    [background addSubview:label_l3_01];
    
    UITextField *xTextField = [[UITextField alloc] initWithFrame:CGRectMake(75, 10 + LineHeight * 2, CellWidth, CellHeight)];
    xTextField.delegate = self;
    xTextField.contentVerticalAlignment = UIControlContentVerticalAlignmentCenter;//垂直居中
    xTextField.borderStyle = UITextBorderStyleRoundedRect;
    [background addSubview:xTextField];
    xTextField.placeholder = @"";
    xTextField.font = [UIFont systemFontOfSize:ConFontOfSize];
    
    UILabel *label_l3_02 = [[UILabel alloc] initWithFrame:CGRectMake(160, 10 + LineHeight * 2, CellWidth, CellHeight)];
    label_l3_02.text = @"出发时间:";
    label_l3_02.font = [UIFont systemFontOfSize:ConFontOfSize];
    [background addSubview:label_l3_02];

    UITextField *startingTimeTextField = [[UITextField alloc] initWithFrame:CGRectMake(225, 10 + LineHeight * 2, CellWidth, CellHeight)];
    startingTimeTextField.delegate = self;
    startingTimeTextField.contentVerticalAlignment = UIControlContentVerticalAlignmentCenter;//垂直居中
    startingTimeTextField.borderStyle = UITextBorderStyleRoundedRect;
    [background addSubview:startingTimeTextField];
    startingTimeTextField.placeholder = @"";
    startingTimeTextField.font = [UIFont systemFontOfSize:ConFontOfSize];
    #pragma mark line4--------------------
    UILabel *label_l4_01 = [[UILabel alloc] initWithFrame:CGRectMake(LeftMargin, 10 + LineHeight * 3, CellWidth, CellHeight)];
    label_l4_01.text = @"预计费用:";
    label_l4_01.font = [UIFont systemFontOfSize:ConFontOfSize];
    [background addSubview:label_l4_01];
    
    UITextField *costEstimatesTextField = [[UITextField alloc] initWithFrame:CGRectMake(75, 10 + LineHeight * 3, CellWidth * 2 + 70, CellHeight)];
    costEstimatesTextField.delegate = self;
    costEstimatesTextField.contentVerticalAlignment = UIControlContentVerticalAlignmentCenter;//垂直居中
    costEstimatesTextField.borderStyle = UITextBorderStyleRoundedRect;
    [background addSubview:costEstimatesTextField];
    costEstimatesTextField.placeholder = @"";
    costEstimatesTextField.font = [UIFont systemFontOfSize:ConFontOfSize];
    #pragma mark line5--------------------
    UILabel *label_l5_01 = [[UILabel alloc] initWithFrame:CGRectMake(LeftMargin, 10 + LineHeight * 4, CellWidth, CellHeight)];
    label_l5_01.text = @"预计距离:";
    label_l5_01.font = [UIFont systemFontOfSize:ConFontOfSize];
    [background addSubview:label_l5_01];
    
    UITextField *distanceEstimatesTextField = [[UITextField alloc] initWithFrame:CGRectMake(75, 10 + LineHeight * 4, CellWidth * 2 + 70, CellHeight)];
    distanceEstimatesTextField.delegate = self;
    distanceEstimatesTextField.contentVerticalAlignment = UIControlContentVerticalAlignmentCenter;//垂直居中
    distanceEstimatesTextField.borderStyle = UITextBorderStyleRoundedRect;
    [background addSubview:distanceEstimatesTextField];
    distanceEstimatesTextField.placeholder = @"";
    distanceEstimatesTextField.font = [UIFont systemFontOfSize:ConFontOfSize];
    #pragma mark line6--------------------
    UILabel *label_l6_01 = [[UILabel alloc] initWithFrame:CGRectMake(LeftMargin, 10 + LineHeight * 5, CellWidth, CellHeight)];
    label_l6_01.text = @"返回时间:";
    label_l6_01.font = [UIFont systemFontOfSize:ConFontOfSize];
    [background addSubview:label_l6_01];
    
    UITextField *backTimeTextField = [[UITextField alloc] initWithFrame:CGRectMake(75, 10 + LineHeight * 5, CellWidth * 2 + 70, CellHeight)];
    backTimeTextField.delegate = self;
    backTimeTextField.contentVerticalAlignment = UIControlContentVerticalAlignmentCenter;//垂直居中
    backTimeTextField.borderStyle = UITextBorderStyleRoundedRect;
    [background addSubview:backTimeTextField];
    backTimeTextField.placeholder = @"";
    backTimeTextField.font = [UIFont systemFontOfSize:ConFontOfSize];
    #pragma mark line7--------------------
    UILabel *label_l7_01 = [[UILabel alloc] initWithFrame:CGRectMake(LeftMargin, 10 + LineHeight * 6, CellWidth, CellHeight)];
    label_l7_01.text = @"备注:";
    label_l7_01.font = [UIFont systemFontOfSize:ConFontOfSize];
    [background addSubview:label_l7_01];
    
    UITextView *textView_01 = [[UITextView alloc]initWithFrame:CGRectMake(LeftMargin, 10 + LineHeight * 7, frame.size.width - 20, CellHeight * 2)];
    [background addSubview:textView_01];
    #pragma mark line8--------------------
    UILabel *label_l8_01 = [[UILabel alloc] initWithFrame:CGRectMake(LeftMargin, 10 + LineHeight * 9, CellWidth, CellHeight)];
    label_l8_01.text = @"驳回原因:";
    label_l8_01.font = [UIFont systemFontOfSize:ConFontOfSize];
    [background addSubview:label_l8_01];
    
    UITextView *textView_02 = [[UITextView alloc]initWithFrame:CGRectMake(LeftMargin, 10 + LineHeight * 10, frame.size.width - 20, CellHeight * 2)];
    [background addSubview:textView_02];
}

- (void)didReceiveMemoryWarning
{
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

/*
#pragma mark - Navigation

// In a storyboard-based application, you will often want to do a little preparation before navigation
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
    // Get the new view controller using [segue destinationViewController].
    // Pass the selected object to the new view controller.
}
*/


//下拉列表-------------

@end
